﻿CREATE TRIGGER LoanInstallmentWarningAttachment_Tracking_Delete
ON [dbo].[LoanInstallmentWarningAttachment] 
AFTER delete
AS 
BEGIN
	UPDATE Sync.LoanInstallmentWarningAttachment_Tracking 
	SET LastUpdatedDate  = getdate(),
		IsDeleted = 1
	FROM Sync.LoanInstallmentWarningAttachment_Tracking s JOIN DELETED i
    ON s.LoanInstallmentWarningAttachmentID = i.LoanInstallmentWarningAttachmentID
END











